package com.link.base.base.stocksellstorage.service;

import com.link.base.base.stocksellstorage.dao.mybatis.mapper.StocktakingItemMapper;
import com.link.base.base.stocksellstorage.model.StocktakingItem;
import com.link.core.basic.dao.mapper.BasicMapper;
import com.link.core.basic.service.BasicServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;


/**
 * @author 程厚霖
 * @date 2018-08-01
 */
@Service
public class StocktakingItemServiceImpl extends BasicServiceImpl<StocktakingItem> implements StocktakingItemService {

    @Resource
    private StocktakingItemMapper stocktakingItemMapper;

    @Override
    public BasicMapper<StocktakingItem> getBasicMapper() {
        return stocktakingItemMapper;
    }

    /**
     * 根据盘点头删除盘点行
     *
     * @param stocktakingItem
     * @throws Exception
     */
    @Override
    public void deleteByStocktakingId(StocktakingItem stocktakingItem) throws Exception {
        stocktakingItemMapper.deleteByStocktakingId(stocktakingItem);
    }
}
